# coding=utf-8

from urllib.parse import unquote_plus as urlquote
#生产环境配置

RELEASE_VERSION="201905010000"

# coding=utf-8
#本地环境配置文件
DEBUG = False
#mysql
#打印SQL语句
SQLALCHEMY_ECHO = False
SQLALCHEMY_DATABASE_URI = "mysql+pymysql://root:%s@172.17.0.1:3306/guagua?charset=utf8mb4" % urlquote('Nianjia2018614@TwentiesPlus.com')
SQLALCHEMY_TRACK_MODIFICATIONS = False
SQLALCHEMY_ENCODING = "utf8mb4"
SQLALCHEMY_POOL_SIZE = 50


STATIC_PREFIX = "/home/GuaGua/static/"
UPLOAD_PREFIX = "/home/GuaGua/static/upload/"

#
# APP = {
#     'domain':'http://www.twentiesplus.com'
# }
APP = {
    'domain':'https://www.twentiesplus.com'
}

REDIS = {
    "CACHE_TYPE": "redis",
    "CACHE_REDIS_HOST": "172.17.0.1",
    "CACHE_REDIS_PORT": 6379,
    "CACHE_REDIS_DB": 1,
    "CACHE_REDIS_PASSWORD": "",
}



CACHE = {
    "CACHE_TYPE": "redis",
    "CACHE_REDIS_HOST": "172.17.0.1",
    "CACHE_REDIS_PORT": 6379,
    "CACHE_REDIS_DB": 1,
    "CACHE_REDIS_PASSWORD": "NianJia2018614",
}


MONGODB_SETTINGS = {
    "host":'172.17.0.1',
    "port":27017,
    "username":'root',
    "password":'NianJia2018614',
    "db":"guagua",
    "authentication_source" : "admin"
}

PYMONGO = {
    "URI":"mongodb://%s:%s/%s" % (MONGODB_SETTINGS["host"], MONGODB_SETTINGS["port"], MONGODB_SETTINGS["db"]),
    "MONGO_USERNAME": MONGODB_SETTINGS["username"],
    "MONGO_PASSWORD": MONGODB_SETTINGS["password"],
}

